package at.fhj.itm11.forum.beans.stubs;

import java.util.Date;
import java.util.List;

import at.fhj.itm11.forum.service.TopicService;
import at.fhj.itm11.forum.service.dtos.TopicDTO;
import at.fhj.itm11.forum.service.dtos.UserDTO;

public class TopicServiceStub implements TopicService {
	
	public static final Long EXISTING_ID_WITH_POSTS = 1L;
	public static final Long EXISTING_ID_WITHOUT_POSTS = 2L;
	public static final Long NOT_EXISTING_ID = -1L;

	@Override
	public TopicDTO findById(Long id) {
		if(id == EXISTING_ID_WITH_POSTS || id == EXISTING_ID_WITHOUT_POSTS) {
			TopicDTO t = new TopicDTO();
			t.setId(id);
			return t;
		}
		
		return null;
	}

	@Override
	public List<TopicDTO> retrieveAllTopicsOrderedByTitle() {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public void register(TopicDTO topic, UserDTO author, Date date) {
		// TODO Auto-generated method stub

	}

}
